Skip to content

feat(canvas): gracefully filter excluded fields based on metrics security policy#9549

Open
burnerlee wants to merge 1 commit into
rilldata:mainfrom
burnerlee:burnerlee/filter-canvas-components-by-metrics-policy
Open

feat(canvas): gracefully filter excluded fields based on metrics security policy#9549
burnerlee wants to merge 1 commit into
rilldata:mainfrom
burnerlee:burnerlee/filter-canvas-components-by-metrics-policy

Conversation

@burnerlee

@burnerlee burnerlee commented Jun 11, 2026

Copy link
Copy Markdown

When a metrics view security policy excludes a measure or dimension, canvas components now silently drop those fields instead of showing a ComponentError or a stuck loading/floating UI.

  • KPI Grid: excluded measures are filtered from the grid before rendering — only accessible KPIs are shown
  • Table (flat): inaccessible columns are silently dropped; only errors if no columns remain
  • Pivot: inaccessible measures/dimensions are filtered out; only errors if nothing usable remains
  • Leaderboard: same filtering approach as table
  • Pivot display now passes isLoading state to the schema validator to prevent a brief "Metrics view not found" error on initial load

Closes 8850

Checklist:

  • Covered by tests
  • Ran it and it works as intended
  • Reviewed the diff before requesting a review
  • Checked for unhandled edge cases
  • Linked the issues it closes
  • Checked if the docs need to be updated. If so, create a separate Linear DOCS issue
  • Intend to cherry-pick into the release branch
  • I'm proud of this work!

…rity policy

When a metrics view security policy excludes a measure or dimension,
canvas components now silently drop the excluded fields instead of
showing a ComponentError or stuck loading state.

- KPI Grid: filters out excluded measures before rendering; shows
  only the KPIs the current user can access
- Table (flat): filters inaccessible columns; only errors if no
  columns remain
- Pivot: filters inaccessible measures/dimensions; only errors if
  nothing usable remains
- Leaderboard: filters inaccessible measures/dimensions consistently
- Pivot display now passes loading state to validator to avoid a
  brief "Metrics view not found" flash on initial load

Closes rilldata#8850
@burnerlee burnerlee force-pushed the burnerlee/filter-canvas-components-by-metrics-policy branch from 247ba9d to 94ed2ee Compare June 11, 2026 17:10
@burnerlee burnerlee marked this pull request as draft June 11, 2026 17:10
@burnerlee burnerlee marked this pull request as ready for review June 11, 2026 18:41
@nishantmonu51 nishantmonu51 added Type:Feature New feature request Area:Dashboard Size:M Medium change: 100-499 lines labels Jun 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area:Dashboard Size:M Medium change: 100-499 lines Type:Feature New feature request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants